package com.zl.servlet;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * User: c3t Date: 13-11-14 Time: 下午12:03
 */
public class AjaxHelloServlet extends HttpServlet {

	protected void doRequest(HttpServletRequest req, HttpServletResponse resp) throws ServletException,
			IOException {
		System.out.println("ajax coming");
		resp.getWriter().println("ajax hello world");
	}

  @Override
  protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException,
      IOException {
    this.doRequest(req, resp);
  }

  @Override
  protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException,
      IOException {
	  this.doRequest(req, resp);
  }
}
